<template>
  <view class="video">
    <u-navbar :title="titleText" :immersive="true" height="44" background=""   back-icon-color="#FFFFFF" :is-back="true" title-color="#FFFFFF"
              :border-bottom="false" title-width="500">
    </u-navbar>
    <video
        :src="videoUrl"
        autoplay="true"
        play-btn-position="center"
        loop="true"
        show-mute-btn="false"
        show-loading="true"
        enable-play-gesture="true"
        page-gesture="true"
        style="width: 100%;height: 100%;"></video>
  </view>
</template>

<script>
const app = getApp();
export default {
  data() {
    return {
      BestImgUrl: app.globalData.imgurlBwc,
      titleText: '视频',
      SwpierList: [],
      videoUrl: '',
    };
  },
  onLoad(options) {
    this.GetLunbo()
  },
  methods: {
    GetLunbo() {
      let that = this
      that.$api.gethomeBanner({

      }).then(res => {
        console.log('轮播图', res.data.result);
        this.SwpierList = res.data.result
        this.videoUrl = res.data.result[0].video_url
      }).catch(err => {

      })
    },
  }
}
</script>

<style lang="scss">
page{
  width: 100%;
  height: 100%;
}
.video{
  width: 100%;
  height: 100%;
}
</style>
